<template>
  <div>
     <el-carousel class="model1" :interval="5000" arrow="always" height="600px;">
      <el-carousel-item v-for="(item,index) in header" :key="index" class="sywz" >
      <img class="imdt" :src="item.url" />
        <p class="medium1" >{{item.name}}</p>
        <p class="medium2" >{{item.con}}</p>
      </el-carousel-item>
    </el-carousel>
    <!-- <div class="model1"></div> -->

    <div class="model2">
      <div class="photo">
      <p
        style="
          font-size: 42px;
          font-family: DFLiJinHeiW8-GB, DFLiJinHeiW8-GB-Regular;
          font-weight: 400;
          text-align: center;
          color: #279e70;
          line-height: 120px;
          margin: 0;
        "
      >
        通知公告
        <span style="position: relative;top: -85px;font-size:25px;">
          TONGZHIGONGGAO
        </span>
      </p>
    </div>
      <div class="jdzs" :style="index == 0 ? '':'margin-top: 20px;'" v-for="(item,index) in list" :key="index" @click="toDetail(item)">
        <div class="imgStyle">
          <img :src="item.thumb" style="width:100%;height:100%;"/>
        </div>
        <div class="titleStyle">
          <div class="btwz">
            <p style="margin-top: 0;width: 548px;
            font-size: 20px;
            font-family: PingFang SC, PingFang SC-Semibold;
            font-weight: 600;
            text-align: left;
            color: #000000;
            line-height: 28px;
            overflow: hidden;
            display: -webkit-box;
            -webkit-line-clamp: 1;
            -webkit-box-orient: vertical;
            text-overflow: ellipsis;">{{item.title}}</p>
          </div>
          <!-- <div class="btwz1" style="margin-left:20px;"></div> -->
          <div class="btwz2">
            <span>
              {{item.note}}
            </span>
          </div>
          <div style="position: relative;margin-top: -132px;left: 71%;width: 100px;">
            <p style="font-size: 27px;
font-family: Microsoft YaHei, Microsoft YaHei-Regular;
font-weight: 400;
text-align: left;
color: #333333;
line-height: 28px;margin-bottom:0px">{{item.re_monday}}</p>
            <p style="font-size: 16px;
font-family: Microsoft YaHei, Microsoft YaHei-Regular;
font-weight: 400;
text-align: left;
color: #d9d9d9;
line-height: 28px;margin-top:9px;">{{item.re_year}}</p>
          </div>
          <div style="position: relative;margin-top: -70px;left: 85%;width: 100px;">
            <img src="../assets/image/tz.png" />
          </div>
          </div>
      </div>
      </div>
    </div>
</template>
<script>
import { service } from '@/request'
// import { service } from "@/request";
export default {
  data () {
    return {
      header: [],
      list: []
    }
  },
  created () {},
  mounted () {
    this.Carousel()
    this.getList()
  },
  methods: {
    toDetail (item) {
      this.$router.push(
        {
          path: '/lqxx',
          query: {
            id: item.id,
            origin: 'notice'
          }
        }
      )
    },
    // 获取列表
    getList () {
      service({
        url: '/go/activitylist',
        method: 'post',
        data: {
          ttype: 1
        }
      }).then((data) => {
        if (data.code == 200) {
          this.list = data.data
          // this.hdxq = this.list[0]
        }
      })
    },
    // 轮播图
    Carousel () {
      service({
        url: '/go/carousel',
        method: 'post',
        data: {}
      }).then((data) => {
        if (data.code == 200) {
          this.header = data.data
        }
      })
    }
  }
}
</script>
<style scoped>
.model1 {
  width: 99.9%;
  height: 600px;
  background: url("../assets/image/dpm1.png") no-repeat;
  background-size: 100% 100%;
}
.model2 {
  width: 99.9%;
  min-height: 360px;
  display: flex;
  justify-content: center;
  align-content: center;
  align-items: center;
  background: url('../assets/image/dbj2.png') no-repeat;
  background-size: 100% 100%;
  flex-direction: column;
  padding-bottom: 20px;
}
.photo {
  width: 333px;
  height: 158px;
  text-align: center;
  background: url("../assets/image/gysq.png") no-repeat;
  background-size: 100% 100%;
  display: flex;
  justify-content: center;
  /* position: absolute;
  left: 41%;
  top: 64%; */
  /* display: block; */
}
.bzjd {
  width: 70%;
  height: 60%;
  display: flex;
  justify-content: space-between;
}
.box1 {
  width: 30%;
  height: 100%;
  display: inline-block;
}
.model3 {
  width: 99.9%;
  height: 400px;
  display: flex;
  justify-content: center;
  align-content: center;
  align-items: center;
}
.jdzs {
  width: 70%;
  height: 135px;
}
.imgStyle {
  width: 30%;
  height: 100%;
  display: inline-block;
  float: left;
  background: url("../assets/image/jd1.png") no-repeat;
  background-size: 100% 100%;
}
.titleStyle {
  width: 69.5%;
  height: 100%;
  display: inline-block;
  background: transparent;
}
.btwz {
  font-size: 31px;
  font-family: Source Han Sans SC, Source Han Sans SC-Regular;
  font-weight: 400;
  text-align: left;
  color: #000000;
  line-height: 28px;
  margin-left: 25px;
  display: inline-block;
}
.btwz1 {
  font-size: 14px;
  font-family: Source Han Sans SC, Source Han Sans SC-Regular;
  font-weight: 400;
  text-align: left;
  color: #000000;
  line-height: 28px;
  margin-left: 25px;
  width: 548px;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  text-overflow: ellipsis;
}
.btwz2 {
  font-size: 14px;
  font-family: Source Han Sans SC, Source Han Sans SC-Regular;
  font-weight: 400;
  text-align: left;
  color: #000000;
  line-height: 28px;
  margin-left: 25px;
  width: 548px;
  overflow: hidden;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  text-overflow: ellipsis;
  display: inline-block;
  height: 90px;

  display: -webkit-box;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
  -webkit-line-clamp: 3; /* 显示的最大行数 */
}
/deep/ .el-carousel__container {
    position: relative;
    height: 600px;
}
 .imdt{
  width: 100%;
  height: 100%;

 }
.medium2{
position: absolute;
    left: 5rem;
    bottom: 10rem;
    font-size: 50px;
    color: white;
    /* text-decoration-line: underline; */
    font-weight: 900;
    font-family:Georgia, 'Times New Roman', Times, serif;
    font-size: 48px;
    line-height: 100%;
    display: flex;
    align-items: center;
    flex: none;
    order: 1;
    align-self: stretch;
}
.medium1{
    position: absolute;
    left: 5rem;
    bottom: 15rem;
    font-size: 50px;
    color: white;
    /* text-decoration-line: underline; */
    font-weight: 900;
    font-family:Georgia, 'Times New Roman', Times, serif;
    font-size: 48px;
    line-height: 100%;
    display: flex;
    align-items: center;
    flex: none;
    order: 1;
    align-self: stretch;
}
</style>
